import jpush

p1 = "13439993696"
p2 = "18510508147"
p3 = "18612536841"
p3 = "13651153502"

app_key = "d6380f9b031374ef02b19a8f"
master_secret = "41e81a02afa377649be81bc6"

_jpush = jpush.JPush(app_key, master_secret)


def alias():
    push = _jpush.create_push()
    alias = [p1, p2, p3]
    alias1 = {"alias": alias}
    print(alias1)
    push.audience = jpush.audience(
        # jpush.tag("tag1", "tag2"),
        alias1
    )

    push.notification = jpush.notification(alert="Hello with python from 蔡京龙")
    push.platform = jpush.all_
    push.options = {"apns_production": False}

    print(push.payload)

    push.send()


alias()
